package requests

import (
	"github.com/goravel/framework/contracts/http"
	"github.com/goravel/framework/contracts/validation"
)

type ManhourRequest struct {
	KindID    uint    `form:"kind_id" json:"kind_id"`
	ServiceID uint    `form:"service_id" json:"service_id"`
	Score     float64 `form:"score" json:"score"`
}

func (r *ManhourRequest) Authorize(ctx http.Context) error {
	return nil
}

func (r *ManhourRequest) Rules(ctx http.Context) map[string]string {
	return map[string]string{
		"kind_id":    "required",
		"service_id": "required",
		"score":      "required",
	}
}

func (r *ManhourRequest) Messages(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *ManhourRequest) Attributes(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *ManhourRequest) PrepareForValidation(ctx http.Context, data validation.Data) error {
	return nil
}
